//
//  QDBusLineTableViewCell.swift
//  QDMetroClient
//
//  Created by YueWen on 2019/4/12.
//  Copyright © 2019 YueWen. All rights reserved.
//

import UIKit

/// 公交线路显示样式
final class QDBusLineTableViewCell: NWTableViewCell {

    /// 显示线路的标签
    let titleLabel = UILabel()
    /// 显示方向的标签
    let lineLabel = UILabel()
    
    override func buildView() {
        super.buildView()
        
        titleLabel.textColor = QDColors.black
        titleLabel.font = Font.medium.font(size: 16)
        
        lineLabel.textColor = QDColors.gray
        lineLabel.font = Font.regular.font(size: 16)
        
        bottomLineView.backgroundColor = #colorLiteral(red: 0.8901960784, green: 0.9019607843, blue: 0.8941176471, alpha: 1)
        bottomLineInset.left = 20
        bottomLineInset.right = 20
        bottomLineHeight = 0.5
        
        contentView.addSubview(titleLabel)
        contentView.addSubview(lineLabel)
        
        titleLabel.snp.makeConstraints { (make) in
            make.left.equalToSuperview().offset(20)
            make.top.equalToSuperview().offset(10)
            make.height.equalTo(22)
        }
        
        lineLabel.snp.makeConstraints { (make) in
            make.left.equalToSuperview().offset(20)
            make.top.equalTo(titleLabel.snp.bottom).offset(3)
            make.height.equalTo(22)
        }
    }
}
